﻿<?xml version="1.0" encoding="utf-8"?>
<xs:schema id="ESRPDataSetDistributie" targetNamespace="http://tempuri.org/ESRPDataSetDistributie.xsd" xmlns:mstns="http://tempuri.org/ESRPDataSetDistributie.xsd" xmlns="http://tempuri.org/ESRPDataSetDistributie.xsd" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata" xmlns:msprop="urn:schemas-microsoft-com:xml-msprop" attributeFormDefault="qualified" elementFormDefault="qualified">
  <xs:annotation>
    <xs:appinfo source="urn:schemas-microsoft-com:xml-msdatasource">
      <DataSource DefaultConnectionIndex="0" FunctionsComponentName="QueriesTableAdapter" Modifier="AutoLayout, AnsiClass, Class, Public" SchemaSerializationMode="IncludeSchema" xmlns="urn:schemas-microsoft-com:xml-msdatasource">
        <Connections>
          <Connection ConnectionStringObject="Data Source=localhost;Initial Catalog=ESRP;User ID=User" IsAppSettingsProperty="false" Modifier="Assembly" Name="eco101.ESRP.dbo" ParameterPrefix="@" Provider="System.Data.SqlClient" />
        </Connections>
        <Tables>
          <TableAdapter BaseClass="System.ComponentModel.Component" DataAccessorModifier="AutoLayout, AnsiClass, Class, Public" DataAccessorName="AgentiTableAdapter" GeneratorDataComponentClassName="AgentiTableAdapter" Name="Agenti" UserDataComponentName="AgentiTableAdapter">
            <MainSource>
              <DbSource ConnectionRef="eco101.ESRP.dbo" DbObjectName="ESRP.dbo.Agenti" DbObjectType="Table" FillMethodModifier="Public" FillMethodName="Fill" GenerateMethods="Both" GenerateShortCommands="true" GeneratorGetMethodName="GetData" GeneratorSourceName="Fill" GetMethodModifier="Public" GetMethodName="GetData" QueryType="Rowset" ScalarCallRetval="System.Object, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" UseOptimisticConcurrency="true" UserGetMethodName="GetData" UserSourceName="Fill">
                <DeleteCommand>
                  <DbCommand CommandType="Text" ModifiedByUser="false">
                    <CommandText>DELETE FROM [dbo].[Agenti] WHERE (([IDAgent] = @Original_IDAgent) AND ([NumePrenume] = @Original_NumePrenume) AND ([CodUnitate] = @Original_CodUnitate))</CommandText>
                    <Parameters>
                      <Parameter AllowDbNull="false" AutogeneratedName="" DataSourceName="" DbType="Int32" Direction="Input" ParameterName="@Original_IDAgent" Precision="0" ProviderType="Int" Scale="0" Size="0" SourceColumn="IDAgent" SourceColumnNullMapping="false" SourceVersion="Original" />
                      <Parameter AllowDbNull="false" AutogeneratedName="" DataSourceName="" DbType="AnsiString" Direction="Input" ParameterName="@Original_NumePrenume" Precision="0" ProviderType="VarChar" Scale="0" Size="0" SourceColumn="NumePrenume" SourceColumnNullMapping="false" SourceVersion="Original" />
                      <Parameter AllowDbNull="false" AutogeneratedName="" DataSourceName="" DbType="Int16" Direction="Input" ParameterName="@Original_CodUnitate" Precision="0" ProviderType="SmallInt" Scale="0" Size="0" SourceColumn="CodUnitate" SourceColumnNullMapping="false" SourceVersion="Original" />
                    </Parameters>
                  </DbCommand>
                </DeleteCommand>
                <InsertCommand>
                  <DbCommand CommandType="Text" ModifiedByUser="false">
                    <CommandText>INSERT INTO [dbo].[Agenti] ([NumePrenume], [CodUnitate]) VALUES (@NumePrenume, @CodUnitate);
SELECT IDAgent, NumePrenume, CodUnitate FROM Agenti WHERE (IDAgent = SCOPE_IDENTITY())</CommandText>
                    <Parameters>
                      <Parameter AllowDbNull="false" AutogeneratedName="" DataSourceName="" DbType="AnsiString" Direction="Input" ParameterName="@NumePrenume" Precision="0" ProviderType="VarChar" Scale="0" Size="0" SourceColumn="NumePrenume" SourceColumnNullMapping="false" SourceVersion="Current" />
                      <Parameter AllowDbNull="false" AutogeneratedName="" DataSourceName="" DbType="Int16" Direction="Input" ParameterName="@CodUnitate" Precision="0" ProviderType="SmallInt" Scale="0" Size="0" SourceColumn="CodUnitate" SourceColumnNullMapping="false" SourceVersion="Current" />
                    </Parameters>
                  </DbCommand>
                </InsertCommand>
                <SelectCommand>
                  <DbCommand CommandType="Text" ModifiedByUser="false">
                    <CommandText>SELECT IDAgent, NumePrenume, CodUnitate FROM dbo.Agenti</CommandText>
                    <Parameters />
                  </DbCommand>
                </SelectCommand>
                <UpdateCommand>
                  <DbCommand CommandType="Text" ModifiedByUser="false">
                    <CommandText>UPDATE [dbo].[Agenti] SET [NumePrenume] = @NumePrenume, [CodUnitate] = @CodUnitate WHERE (([IDAgent] = @Original_IDAgent) AND ([NumePrenume] = @Original_NumePrenume) AND ([CodUnitate] = @Original_CodUnitate));
SELECT IDAgent, NumePrenume, CodUnitate FROM Agenti WHERE (IDAgent = @IDAgent)</CommandText>
                    <Parameters>
                      <Parameter AllowDbNull="false" AutogeneratedName="" DataSourceName="" DbType="AnsiString" Direction="Input" ParameterName="@NumePrenume" Precision="0" ProviderType="VarChar" Scale="0" Size="0" SourceColumn="NumePrenume" SourceColumnNullMapping="false" SourceVersion="Current" />
                      <Parameter AllowDbNull="false" AutogeneratedName="" DataSourceName="" DbType="Int16" Direction="Input" ParameterName="@CodUnitate" Precision="0" ProviderType="SmallInt" Scale="0" Size="0" SourceColumn="CodUnitate" SourceColumnNullMapping="false" SourceVersion="Current" />
                      <Parameter AllowDbNull="false" AutogeneratedName="" DataSourceName="" DbType="Int32" Direction="Input" ParameterName="@Original_IDAgent" Precision="0" ProviderType="Int" Scale="0" Size="0" SourceColumn="IDAgent" SourceColumnNullMapping="false" SourceVersion="Original" />
                      <Parameter AllowDbNull="false" AutogeneratedName="" DataSourceName="" DbType="AnsiString" Direction="Input" ParameterName="@Original_NumePrenume" Precision="0" ProviderType="VarChar" Scale="0" Size="0" SourceColumn="NumePrenume" SourceColumnNullMapping="false" SourceVersion="Original" />
                      <Parameter AllowDbNull="false" AutogeneratedName="" DataSourceName="" DbType="Int16" Direction="Input" ParameterName="@Original_CodUnitate" Precision="0" ProviderType="SmallInt" Scale="0" Size="0" SourceColumn="CodUnitate" SourceColumnNullMapping="false" SourceVersion="Original" />
                      <Parameter AllowDbNull="false" AutogeneratedName="IDAgent" ColumnName="IDAgent" DataSourceName="ESRP.dbo.Agenti" DataTypeServer="int" DbType="Int32" Direction="Input" ParameterName="@IDAgent" Precision="0" ProviderType="Int" Scale="0" Size="4" SourceColumn="IDAgent" SourceColumnNullMapping="false" SourceVersion="Current" />
                    </Parameters>
                  </DbCommand>
                </UpdateCommand>
              </DbSource>
            </MainSource>
            <Mappings>
              <Mapping SourceColumn="IDAgent" DataSetColumn="IDAgent" />
              <Mapping SourceColumn="NumePrenume" DataSetColumn="NumePrenume" />
              <Mapping SourceColumn="CodUnitate" DataSetColumn="CodUnitate" />
            </Mappings>
            <Sources />
          </TableAdapter>
        </Tables>
        <Sources />
      </DataSource>
    </xs:appinfo>
  </xs:annotation>
  <xs:element name="ESRPDataSetDistributie" msdata:IsDataSet="true" msdata:UseCurrentLocale="true" msprop:EnableTableAdapterManager="True" msprop:Generator_DataSetName="ESRPDataSetDistributie" msprop:Generator_UserDSName="ESRPDataSetDistributie">
    <xs:complexType>
      <xs:choice minOccurs="0" maxOccurs="unbounded">
        <xs:element name="Agenti" msprop:Generator_TableClassName="AgentiDataTable" msprop:Generator_TableVarName="tableAgenti" msprop:Generator_TablePropName="Agenti" msprop:Generator_RowDeletingName="AgentiRowDeleting" msprop:Generator_UserTableName="Agenti" msprop:Generator_RowChangingName="AgentiRowChanging" msprop:Generator_RowEvHandlerName="AgentiRowChangeEventHandler" msprop:Generator_RowDeletedName="AgentiRowDeleted" msprop:Generator_RowEvArgName="AgentiRowChangeEvent" msprop:Generator_RowChangedName="AgentiRowChanged" msprop:Generator_RowClassName="AgentiRow">
          <xs:complexType>
            <xs:sequence>
              <xs:element name="IDAgent" msdata:ReadOnly="true" msdata:AutoIncrement="true" msdata:AutoIncrementSeed="-1" msdata:AutoIncrementStep="-1" msprop:Generator_ColumnVarNameInTable="columnIDAgent" msprop:Generator_ColumnPropNameInRow="IDAgent" msprop:Generator_ColumnPropNameInTable="IDAgentColumn" msprop:Generator_UserColumnName="IDAgent" type="xs:int" />
              <xs:element name="NumePrenume" msprop:Generator_ColumnVarNameInTable="columnNumePrenume" msprop:Generator_ColumnPropNameInRow="NumePrenume" msprop:Generator_ColumnPropNameInTable="NumePrenumeColumn" msprop:Generator_UserColumnName="NumePrenume">
                <xs:simpleType>
                  <xs:restriction base="xs:string">
                    <xs:maxLength value="50" />
                  </xs:restriction>
                </xs:simpleType>
              </xs:element>
              <xs:element name="CodUnitate" msprop:Generator_ColumnVarNameInTable="columnCodUnitate" msprop:Generator_ColumnPropNameInRow="CodUnitate" msprop:Generator_ColumnPropNameInTable="CodUnitateColumn" msprop:Generator_UserColumnName="CodUnitate" type="xs:short" />
            </xs:sequence>
          </xs:complexType>
        </xs:element>
      </xs:choice>
    </xs:complexType>
    <xs:unique name="Constraint1" msdata:PrimaryKey="true">
      <xs:selector xpath=".//mstns:Agenti" />
      <xs:field xpath="mstns:IDAgent" />
    </xs:unique>
  </xs:element>
</xs:schema>